-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
chore: migration to vite+ #5709
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: next
Are you sure you want to change the base?
Conversation
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. ✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR migrates the Eggjs monorepo from oxlint/oxfmt tooling to vite+ (a custom tooling suite from VoidZero). The migration consolidates linting, formatting, and testing under a unified vite-based toolchain.
Key Changes:
- Replaces oxlint/oxfmt with vite+ commands across all packages and scripts
- Migrates vitest to @voidzero-dev/vite-plus-test package alias
- Introduces centralized vite.config.ts for format and lint configuration
- Adds GitHub package registry authentication for @voidzero-dev packages
Reviewed changes
Copilot reviewed 42 out of 43 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| vite.config.ts | New centralized configuration file migrating settings from .oxlintrc.json and .oxfmtrc.json |
| pnpm-workspace.yaml | Updates catalog to replace oxlint/oxfmt with vite+ packages; adds peer dependency rules and overrides |
| .npmrc | Configures GitHub package registry authentication for @voidzero-dev scoped packages |
| package.json (root) | Updates scripts to use vite commands; replaces oxlint/oxfmt devDependencies with @voidzero-dev/vite-plus |
| .oxlintrc.json | Removed - configuration migrated to vite.config.ts |
| .oxfmtrc.json | Removed - configuration migrated to vite.config.ts |
| packages/*/package.json | Updates lint/test scripts from oxlint/vitest to vite lint/vite test; removes oxlint devDependencies |
| plugins/*/package.json | Updates lint/test scripts from oxlint/vitest to vite lint/vite test; removes oxlint devDependencies |
| tools/*/package.json | Updates lint/test scripts from oxlint/vitest to vite lint/vite test; removes oxlint devDependencies |
| examples/*/package.json | Updates test scripts from vitest to vite test; updates lint commands in some examples |
| vite: 'catalog:' | ||
| vitest: 'catalog:' |
Copilot
AI
Nov 28, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The overrides section now forces both vite and vitest to use the catalog versions (which are aliased to @voidzero-dev packages). This is a significant change from the previous rolldown-vite@^7.1.13 override. Ensure that:
- All packages that depend on vite/vitest are compatible with the vite+ versions
- This doesn't break any existing functionality that relied on the rolldown-vite fork
- The change is intentional and has been tested across all workspace packages
This is a critical override that affects the entire monorepo's build and test infrastructure.
.npmrc
Outdated
| //npm.pkg.github.com/:_authToken=${GITHUB_TOKEN} | ||
| @voidzero-dev:registry=https://npm.pkg.github.com/ |
Copilot
AI
Nov 28, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The GitHub token is being referenced via environment variable ${GITHUB_TOKEN}, but there's no validation or fallback if this variable is not set. This could cause silent failures during package installation. Consider:
- Documenting this requirement in README or CONTRIBUTING.md
- Adding validation in CI/CD pipelines to ensure GITHUB_TOKEN is set
- Providing clear error messages when the token is missing
Additionally, ensure this token has appropriate read permissions for the @voidzero-dev scope packages.
| peerDependencyRules: | ||
| allowAny: | ||
| - vite | ||
| - vitest | ||
| allowedVersions: | ||
| vite: '*' | ||
| vitest: '*' |
Copilot
AI
Nov 28, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The peerDependencyRules configuration uses allowAny and allowedVersions: '*' for both vite and vitest. This effectively disables peer dependency version checking, which could lead to compatibility issues. While this may be necessary for the vite+ migration, consider:
- Whether this is a temporary workaround or permanent solution
- Adding documentation explaining why these broad permissions are needed
- Testing thoroughly to ensure no breaking changes occur from version mismatches
This configuration makes the build less strict and could hide incompatibility issues.
| - oxlint-tsgolint | ||
| - oxlint | ||
| - oxc-minify | ||
| - '@voidzero-dev/*' |
Copilot
AI
Nov 28, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The minimumReleaseAgeExclude list still references oxlint-tsgolint, oxlint, and oxc-minify (lines 240-242), but these packages have been removed from the catalog and are no longer used in the project. While adding @voidzero-dev/* to the exclusion list is correct, consider also removing the obsolete oxlint-related entries to keep the configuration clean and up-to-date.
b55ec07 to
38adb66
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## next #5709 +/- ##
==========================================
+ Coverage 87.40% 90.74% +3.33%
==========================================
Files 561 6 -555
Lines 10932 54 -10878
Branches 1238 12 -1226
==========================================
- Hits 9555 49 -9506
+ Misses 1293 5 -1288
+ Partials 84 0 -84 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
32730ce to
b66932f
Compare
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 79 out of 80 changed files in this pull request and generated 12 comments.
| "lint": "vite lint", | ||
| "typecheck": "tsc --noEmit", | ||
| "test": "vitest run", | ||
| "test": "vite test run", |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The scripts use vite lint and vite test run commands, but @voidzero-dev/vite-plus is missing from devDependencies. Add it to ensure the commands work.
| "lint": "vite lint --type-aware", | ||
| "typecheck": "tsc --noEmit", | ||
| "test": "vitest run", | ||
| "test": "vite test run", |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The scripts use vite lint and vite test run commands, but @voidzero-dev/vite-plus is missing from devDependencies. Add it to ensure the commands work.
| }, | ||
| "scripts": { | ||
| "lint": "oxlint --type-aware", | ||
| "lint": "vite lint --type-aware", |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The lint script uses vite lint command, but @voidzero-dev/vite-plus is missing from devDependencies. Add it to ensure the command works.
| "lint": "vite lint", | ||
| "typecheck": "tsc --noEmit", | ||
| "test": "vitest run", | ||
| "test": "vite test run", |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The scripts use vite lint and vite test run commands, but @voidzero-dev/vite-plus is missing from devDependencies. Add it to ensure the commands work.
| @voidzero-dev:registry=https://npm.pkg.github.com/ | ||
| //npm.pkg.github.com/:_authToken=${VP_TOKEN} No newline at end of file |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The .npmrc file configures authentication for GitHub Packages using an environment variable VP_TOKEN. Ensure this token is properly documented and secured. Consider adding a comment in this file explaining what this token is for and where to obtain it, or reference documentation that explains this.
| "lint": "vite lint --type-aware", | ||
| "test": "vite test run", |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The scripts use vite lint and vite test run commands, but @voidzero-dev/vite-plus is missing from devDependencies. Add it to ensure the commands work.
| "lint": "vite lint --type-aware", | ||
| "typecheck": "tsc --noEmit", | ||
| "test": "vitest run", | ||
| "test": "vite test run", |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The scripts use vite lint and vite test run commands, but @voidzero-dev/vite-plus is missing from devDependencies. Add it to ensure the commands work.
| xss: ^1.0.15 | ||
| ylru: ^2.0.0 | ||
| zod: ^3.24.1 | ||
| vite: npm:@voidzero-dev/vite-plus-core@latest |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The vite catalog entry is aliasing to @voidzero-dev/vite-plus-core@latest which appears to be a different package. This override may break any packages that depend on the standard vite package. Consider whether this alias is necessary or if vite-plus should be used independently.
| on-finished: ^2.4.1 | ||
| onelogger: ^1.0.1 | ||
| oxc-minify: ^0.99.0 |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The oxfmt, oxlint, and oxlint-tsgolint dependencies have been removed from the catalog, but there are still references to oxlint in documentation files (AGENTS.md, CLAUDE.md, .github/copilot-instructions.md, and others). These documentation files should be updated to reflect the migration to vite-plus tooling.
| id-token: write | ||
| actions: write | ||
|
|
||
| env: |
Copilot
AI
Dec 4, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The VP_TOKEN environment variable is added for GitHub Packages authentication to access @voidzero-dev packages. Consider adding a comment or documentation in the workflow explaining what this token is for and how to set it up for contributors, as this is a new external dependency requirement.
| env: | |
| env: | |
| # VP_TOKEN is required for authenticating with GitHub Packages to access @voidzero-dev packages. | |
| # Contributors: Set the VP_TOKEN secret in your repository or organization settings with a valid GitHub Packages token. | |
| # See CONTRIBUTING.md for setup instructions. |
Uh oh!
There was an error while loading. Please reload this page.